package com.stress.testing.common.matcher;

import java.util.Collections;
import java.util.List;

public class ClassDescription {
    private String name;
    private String simpleName;
    private List<FieldDescription> fieldDescriptions;
    private List<MethodDescription> methodDescriptions;

    public ClassDescription(String name, String simpleName) {
        this.name = name;
        this.simpleName = simpleName;
    }

    public ClassDescription(String name, String simpleName,
                            List<FieldDescription> fieldDescriptions,
                            List<MethodDescription> methodDescriptions) {
        this.name = name;
        this.simpleName = simpleName;
        this.fieldDescriptions = fieldDescriptions;
        this.methodDescriptions = methodDescriptions;
    }

    public String getName() {
        return name;
    }

    public String getSimpleName() {
        return simpleName;
    }

    public List<FieldDescription> getFieldDescriptions() {
        if (fieldDescriptions == null) {
            return null;
        }

        return Collections.unmodifiableList(fieldDescriptions);
    }

    public List<MethodDescription> getMethodDescriptions() {
        if (methodDescriptions == null) {
            return null;
        }

        return Collections.unmodifiableList(methodDescriptions);
    }

}
